package com.data.app.commons.constant;


import com.data.app.commons.exception.ErrEnumInterface;

/**
 * @Author Zyl
 * @Date 2021/3/30 15:04
 * @Version 1.0
 * @Describe: 该枚举类功能：封装异常的错误码等信息
 */
public enum ServiceErrEnumInfo implements ErrEnumInterface {


    REQ_PARAM_ERR(10001, "请求参数异常"),

    NOTFOUND_RESULT_ERR(10002, "未找到结果");


    /**
     * 异常编码
     */
    private int code;
    private String message;

    ServiceErrEnumInfo(int code, String msg) {
        this.code = code;
    }

    @Override
    public int getCode() {
        return code;
    }

    @Override
    public String getMessage() {
        return message;
    }

}
